<template>
  <div class="app-container">
    <!-- 头部 -->
    <div class="ProductionDynamicHeader">
      <Find :OriginalFilter="{ static: true }" :formList="formList" @findClicked="findData" />
    </div>

    <el-card class="Main" shadow="always" :body-style="{ padding: '20px' }">
      <div style="display: flex">
        <div style="width: 70%">
          <h1>订单明细</h1>
          <Table :tableData="tableData" :tableHeader="tableHeader" :selection="true" :TableHeight="'130rem'" />
        </div>
        <div style="width: 20%; margin-left: 5rem">
          <h1>号码明细</h1>
          <Table :tableData="tableData1" :tableHeader="tableHeader1" :selection="false" :TableHeight="'130rem'" />
        </div>
      </div>
      <div style="width: 70%; margin-top: 3rem">
        <h1>指令用量明细</h1>
        <Table :tableData="tableData" :tableHeader="tableHeader2" :selection="false" :TableHeight="'130rem'" />
      </div>
      <div style="float: right">
        <el-button style="background-color: #e7e7e7; color: #000000; border: none" type="info" size="small">保存</el-button>
        <el-button style="background-color: #f89027" type="warning" size="small">打印</el-button>
      </div>
    </el-card>
  </div>
</template>
<script lang="ts">
import { defineComponent } from 'vue'
import JMessage from '@/utils/JMessage'
export default defineComponent({
  name: 'InstructionUsage'
})
</script>
<script lang="ts" setup>
import { i18n, Jzhcn } from '@/i18n'
import { ref } from 'vue'
const formList = ref([
  {
    type: 'input',
    inputLabel: '',
    inputValue: '请输入指令'
  },
  {
    type: 'input',
    inputLabel: '',
    inputValue: '请输入型体'
  },
  {
    type: 'input',
    inputLabel: '',
    inputValue: '请输入颜色'
  },
  {
    type: 'input',
    inputLabel: '',
    inputValue: '请输入客人单号'
  },
  {
    type: 'select',
    selectValue: '',
    selectP: '品牌',
    selectLabel: '',
    selectOptions: [
      {
        optionKey: '1',
        optionValue: '111111',
        optionLabel: 'option1'
      },
      {
        optionKey: '2',
        optionValue: '222222',
        optionLabel: 'option2'
      }
    ]
  },
  {
    type: 'select',
    selectValue: '',
    selectP: '是否生成',
    selectLabel: '',
    selectOptions: [
      {
        optionKey: '1',
        optionValue: '111111',
        optionLabel: 'option1'
      },
      {
        optionKey: '2',
        optionValue: '222222',
        optionLabel: 'option2'
      }
    ]
  },
  {
    type: 'date',
    dateLabel: '下单',
    dateValue: ''
  },
  {
    type: 'button',
    checkboxLabel: '置空',
    bgColor: '#1890FF'
  },
  {
    type: 'button',
    checkboxLabel: '置空',
    bgColor: '#1890FF'
  },
  {
    type: 'date',
    dateLabel: '交期',
    dateValue: ''
  },
  {
    type: 'button',
    checkboxLabel: '型体配色生产注意事项'
  },
  {
    type: 'button',
    checkboxLabel: '配码资料查询'
  },
  {
    type: 'button',
    checkboxLabel: '导出指令单'
  },
  {
    type: 'button',
    checkboxLabel: '导号码明细(含预补)'
  },
  {
    type: 'button',
    checkboxLabel: '导号码明细(不含预补)'
  }
])
const findData = (data: any) => {
  console.log(data)
}

// 表格数据
const tableData = [
  {
    date: '20230427',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-02',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-04',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312',
    customer: 'jzy',
    checkboxArrange: true
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  }
]

const tableHeader = ref([
  {
    label: '指令',
    prop: 'customer'
  },
  {
    label: '型体',
    prop: 'instruction'
  },
  {
    label: '下单日期',
    prop: 'shape'
  },
  {
    label: '交期',
    prop: 'shape'
  },
  {
    label: '客户',
    prop: 'shape'
  },
  {
    label: '订单号',
    prop: 'shape'
  },
  {
    label: '底模',
    prop: 'shape'
  },
  {
    label: '楦头',
    prop: 'shape'
  },
  {
    label: '订单数',
    prop: 'shape'
  },
  {
    label: '预补数',
    prop: 'shape'
  },
  {
    label: '检核否',
    prop: 'shape'
  },
  {
    label: '图片',
    fixed: true,
    prop: 'shape'
  }
])

// 表格数据
const tableData1 = [
  {
    date: '20230427',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-02',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-04',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312',
    customer: 'jzy',
    checkboxArrange: true
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  }
]

const tableHeader1 = ref([
  {
    label: '号码',
    prop: 'customer'
  },
  {
    label: '冲刀号',
    prop: 'instruction'
  },
  {
    label: '订单数',
    prop: 'shape'
  },
  {
    label: '预补数',
    prop: 'shape'
  }
])

const tableHeader2 = ref([
  {
    label: '序号',
    prop: 'customer'
  },
  {
    label: '部位',
    prop: 'instruction'
  },
  {
    label: '段',
    prop: 'shape'
  },
  {
    label: '物料编号',
    prop: 'shape'
  },
  {
    label: '分类',
    prop: 'customer'
  },
  {
    label: '分类名称',
    prop: 'instruction'
  },
  {
    label: '材料颜色',
    prop: 'shape'
  },
  {
    label: '材料名称',
    prop: 'shape'
  },
  {
    label: '规格',
    prop: 'customer'
  },
  {
    label: '单位',
    prop: 'instruction'
  },
  {
    label: '尺码起',
    prop: 'shape'
  },
  {
    label: '尺码止',
    prop: 'shape'
  },
  {
    label: '单号',
    prop: 'shape'
  },
  {
    label: '用量',
    prop: 'shape'
  },
  {
    label: '备注',
    prop: 'shape'
  }
])
</script>

<style lang="less" scoped>
.Main {
  margin-top: 8rem;
}

h1 {
  font-size: 16px;
}
</style>
